home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part2 / 12302 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.1 KB

  1. Path: EU.net!sun4nl!xs4all!falstaff
  2. From: falstaff@xs4all.nl (Falstaff)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: Storing C Functions In An Array?
  5. Date: 30 Mar 1996 11:20:00 GMT
  6. Organization: XS4ALL, networking for the masses
  7. Message-ID: <4jj5d0$me8@news.xs4all.nl>
  8. References: <4jc1u7$5e9@infa.central.susx.ac.uk> <4jerhn$sc8@oege.htsa.hva.nl>
  9. NNTP-Posting-Host: xs1.xs4all.nl
  10. X-Newsreader: NN version 6.5.0 #666 (NOV)
  11.  
  12. ferdinan@htsa.htsa.hva.nl (Ferdinand de Boevere) writes:
  13.  
  14. >Storing functions in an array is not possible.
  15. >What you probably mean is storing 'pointers to function'
  16. >in an array.
  17.  
  18. I remember one entry in an early Obfuscated C Programming Contest.
  19. It declared main something like this:
  20.  
  21. int main[]=
  22. {  5236,736,8,-547,'f', 
  23.    .
  24.    .
  25.    etc.
  26. }
  27.  
  28. and it actually ran on PDPs and VAXen.  So it *can* be done :-)
  29. IIRC, that entry was from Delft U of T, in maybe 1988 or so.
  30.  
  31. Frank
  32. --
  33. The famous GIICM now on line:  http://www.xs4all.nl/~falstaff/GIICM.html
  34. ------------------------------------------------------------------------
  35. Frank A. Vorstenbosch        +31-(70)-355 5241        falstaff@xs4all.nl
  36.